// 用户-角色 关联模型
module.exports = (sequelize, Sequelize) => {
    return sequelize.define("users_roles", {
        id: {
            type: Sequelize.UUID,
            notNull: true,
            primaryKey: true,
            defaultValue: Sequelize.UUIDV4,
        },
        userId: {
            type: Sequelize.STRING,
            notNull: true,
            allowNull:false,
            comment: '用户ID',
        },
        roleIds: {
            type: Sequelize.STRING,
            comment: '角色ID',
            allowNull:false,
        }
    });
}